This repository was archived by the owner on Jan 25, 2022. It is now read-only.
fixes #19: remove line terminator normalisation #22
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #19. Implementors have made it clear that they do not plan to implement
Function.prototype.toString
line terminator normalisation due to either performance costs or extreme difficulty in preserving performance. Line terminator normalisation is a feature ofFunction.prototype.toString
that never existed in reality. It was added mostly for consistency with templates and to avoid accidentally observing file encodings. But we are not trying to design a nice API. We are trying to document a legacy feature of JavaScript that would be more appropriate in Annex B. Because of this, we will make it easy for implementors to follow the spec with as few changes to their implementation as possible. The goal of this proposal is to simply further specify theFunction.prototype.toString
behaviour and align implementations where they deviate from each other.